package file;

import java.io.File;
import java.io.IOException;

/**
 * Creared with IntelliJ IDEA.
 * Description:
 * User:yxd
 * Date:2022-04-05
 * Time:18:46
 */
public class Demo3 {
    public static void main(String[] args) throws IOException {
        File f = new File("./text.txt");
        System.out.println("文件是否存在 " + f.exists());
        System.out.println("创建文件");
        f.createNewFile();
        System.out.println("创建文件结束");
        System.out.println("文件是否存在 " + f.exists());
    }
}
